package com.ruoyi.applet.service;

import com.ruoyi.applet.domain.AppletExam;
import com.brisk.common.core.domain.AjaxResult;

import java.util.List;

/**
 * examService接口
 *
 * @author PengFei Deng
 * @date 2022-04-14
 */
public interface IAppletExamService {
    /**
     * 查询exam
     *
     * @param examId exam主键
     * @return exam
     */
    AppletExam selectAppletExamByExamId(Integer examId);

    AppletExam selectAppletExamBySiteId(Long siteId);

    /**
     * 查询exam列表
     *
     * @param appletExam exam
     * @return exam集合
     */
    List<AppletExam> selectAppletExamList(AppletExam appletExam);

    /**
     * 新增exam
     *
     * @param appletExam exam
     * @return 结果
     */
    AjaxResult insertAppletExam(AppletExam appletExam);

    /**
     * 修改exam
     *
     * @param appletExam exam
     * @return 结果
     */
    int updateAppletExam(AppletExam appletExam);

    /**
     * 批量删除exam
     *
     * @param examIds 需要删除的exam主键集合
     * @return 结果
     */
    int deleteAppletExamByExamIds(Integer[] examIds);

    /**
     * 删除exam信息
     *
     * @param examId exam主键
     * @return 结果
     */
    int deleteAppletExamByExamId(Integer examId);


    /**
     * 小程序端查询
     *
     * @param appletExam 对象
     * @return java.util.List<com.ruoyi.applet.domain.AppletExam>
     * @author PengFei Deng
     * @date 2022/4/14 16:36
     */
    List<AppletExam> appletSelect(AppletExam appletExam);


    /**
     * 根据Id查询考试详情
     *
     * @param examId,  isAnswer
     * @param isAnswer 是否要答案 1 有答案 2没有答案
     * @return com.ruoyi.common.core.domain.AjaxResult
     * @author PengFei Deng
     * @date 2022/4/14 16:52
     */
    AjaxResult appletGetByExamId(Integer examId, Integer isAnswer);
}
